<template>
  <div>
    <div class="case-year">
      <h1 class="chart-title">
        年度刑事案件数
      </h1>
      <div>

      </div>
    </div>

    <div class="case-resolved">
      <h1 class="chart-title">
        年度出警数
      </h1>
      <div class="case-resolved-chart" id="caseResolvedChart">

      </div>
    </div>

  </div>
</template>

<script>
import axios from "axios"
import MultiPie from '@/assets/scripts/charts/multiPie'
export default {
 async mounted() {
    let result =await axios.get("/api/overview/alarm")
    var pies = new MultiPie('#caseResolvedChart',{});
    pies.render(result.data.list)
  }
}
</script>

<style lang="scss" scoped>
.case-year {
  position: absolute;
  left: 60px;
  top: 180px;
}

.case-resolved {
  position: absolute;
  left: 60px;
  top: 600px;
}

.case-resolved-chart {
  width: 800px;
  height: 300px;
}
</style>


